How to fix Unterminated expression in f-string; missing close brace in python? - Stack Overflow

s = f'hoge {body['key']}'
ではなく、
s = f'hoge {body["key"]}'